/**
 * @ProjectName:schoolbus
 * @FileName: SchoolBusLog.java
 * @PackageName: edu.xpu.project.log.entity
 * @Company:北京有生博大软件有限公司（西安分公司）
 * @Copyright (c) 2017,RiseSoft  All Rights Reserved.
 * @date 2017年5月26日 下午1:24:05
 */
package edu.xpu.project.log.entity;

import java.io.Serializable;
import java.util.Date;

import javax.persistence.CascadeType;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.ManyToOne;
import javax.persistence.Table;

import edu.xpu.project.vehicle.entity.SchoolBus;

/**
 * @ClassName: SchoolBusLog.java
 * @Description: 校车日志信息
 *
 * @author liukang
 * @date 2017年5月26日 下午1:24:05
 * @version 
 * @since JDK 1.6
 */
@Entity(name="SchoolBusLog")
@Table(name="SCHOOLBUS_LOG")
public class SchoolBusLog implements Serializable {

	private static final long serialVersionUID = 7053078919449376975L;

	@Id
	@GeneratedValue(strategy=GenerationType.IDENTITY)
	private Long id;

	private Date createDate;			//创建时间
	private Long createPersonId;		//创建人id
	
	/**
	 * 日志所属的校车
	 */
	@ManyToOne(optional=true, cascade={CascadeType.REMOVE})
	@JoinColumn(name="bus_id")
	private SchoolBus schoolBus;

	public Long getId() {
		return id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public Date getCreateDate() {
		return createDate;
	}

	public void setCreateDate(Date createDate) {
		this.createDate = createDate;
	}

	public Long getCreatePersonId() {
		return createPersonId;
	}

	public void setCreatePersonId(Long createPersonId) {
		this.createPersonId = createPersonId;
	}

	public SchoolBus getSchoolBus() {
		return schoolBus;
	}

	public void setSchoolBus(SchoolBus schoolBus) {
		this.schoolBus = schoolBus;
	}
	
}

